from django.db import models
from user.models import UserProfile
from video.models import Videos


# Create your models here.
class Favor(models.Model):
    fid = models.AutoField(primary_key=True)
    user_id = models.ForeignKey(UserProfile, on_delete=models.CASCADE, related_name='favor_user_id')
    video_id = models.ForeignKey(Videos, on_delete=models.CASCADE, related_name='favor_video_id')
    is_active = models.BooleanField(default=True)
    time = models.DateTimeField(auto_now=True)
